/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package com.gap.entities;

import com.buanalintas.bynga.entities.MasterUser;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import javax.persistence.Basic;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.JoinColumn;
import javax.persistence.Lob;
import javax.persistence.ManyToOne;
import javax.persistence.OneToMany;
import javax.persistence.Table;
import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import javax.xml.bind.annotation.XmlRootElement;

/**
 *
 * @author Yunita
 */
@Entity
@Table(name = "gap_master_employee")
@XmlRootElement
//@NamedQueries({
//    @NamedQuery(name = "GapMasterEmployee.findAll", query = "SELECT g FROM GapMasterEmployee g"),
//    @NamedQuery(name = "GapMasterEmployee.findBySync", query = "SELECT g FROM GapMasterEmployee g WHERE g.sync = :sync"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeId", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeId = :employeeId"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeFinger", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeFinger = :employeeFinger"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeNumber", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeNumber = :employeeNumber"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeNameFirst", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeNameFirst = :employeeNameFirst"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeNameMiddle", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeNameMiddle = :employeeNameMiddle"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeNameLast", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeNameLast = :employeeNameLast"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeTitleFirst", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeTitleFirst = :employeeTitleFirst"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeTitleLast", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeTitleLast = :employeeTitleLast"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeDateOfBirth", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeDateOfBirth = :employeeDateOfBirth"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeePlaceOfBirth", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeePlaceOfBirth = :employeePlaceOfBirth"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeIdNumber", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeIdNumber = :employeeIdNumber"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeAddress", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeAddress = :employeeAddress"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeePostalCode", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeePostalCode = :employeePostalCode"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeePhone", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeePhone = :employeePhone"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeMobilePhone", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeMobilePhone = :employeeMobilePhone"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeEmail", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeEmail = :employeeEmail"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeMarried", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeMarried = :employeeMarried"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeRegistered", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeRegistered = :employeeRegistered"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeSalaryBasic", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeSalaryBasic = :employeeSalaryBasic"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeePaymentMethod", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeePaymentMethod = :employeePaymentMethod"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeBankAccount", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeBankAccount = :employeeBankAccount"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeBankAccountNumber", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeBankAccountNumber = :employeeBankAccountNumber"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeBankAccountName", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeBankAccountName = :employeeBankAccountName"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeDelegation", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeDelegation = :employeeDelegation"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeActive", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeActive = :employeeActive"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeePlatform", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeePlatform = :employeePlatform"),
//    @NamedQuery(name = "GapMasterEmployee.findByEmployeeStatusBonus", query = "SELECT g FROM GapMasterEmployee g WHERE g.employeeStatusBonus = :employeeStatusBonus")})
public class GapMasterEmployee implements Serializable {
    private static final long serialVersionUID = 1L;
    @Column(name = "sync")
    private String sync;
    @Id
    @Basic(optional = false)
    @Column(name = "employee_id")
    private Integer employeeId;
    @Column(name = "employee_finger")
    private Integer employeeFinger;
    @Column(name = "employee_number")
    private String employeeNumber;
    @Column(name = "employee_name_first")
    private String employeeNameFirst;
    @Column(name = "employee_name_middle")
    private String employeeNameMiddle;
    @Column(name = "employee_name_last")
    private String employeeNameLast;
    @Column(name = "employee_title_first")
    private String employeeTitleFirst;
    @Column(name = "employee_title_last")
    private String employeeTitleLast;
    @Column(name = "employee_date_of_birth")
    @Temporal(TemporalType.DATE)
    private Date employeeDateOfBirth;
    @Column(name = "employee_place_of_birth")
    private String employeePlaceOfBirth;
    @Column(name = "employee_id_number")
    private String employeeIdNumber;
    @Column(name = "employee_address")
    private String employeeAddress;
    @Column(name = "employee_postal_code")
    private String employeePostalCode;
    @Column(name = "employee_phone")
    private String employeePhone;
    @Column(name = "employee_mobile_phone")
    private String employeeMobilePhone;
    @Column(name = "employee_email")
    private String employeeEmail;
    @Column(name = "employee_married")
    private String employeeMarried;
    @Column(name = "employee_registered")
    @Temporal(TemporalType.DATE)
    private Date employeeRegistered;
    // @Max(value=?)  @Min(value=?)//if you know range of your decimal fields consider using these annotations to enforce field validation
    @Column(name = "employee_salary_basic")
    private BigDecimal employeeSalaryBasic;
    @Column(name = "employee_payment_method")
    private String employeePaymentMethod;
    @Column(name = "employee_bank_account")
    private String employeeBankAccount;
    @Column(name = "employee_bank_account_number")
    private String employeeBankAccountNumber;
    @Column(name = "employee_bank_account_name")
    private String employeeBankAccountName;
    @Column(name = "employee_delegation")
    private String employeeDelegation;
    @Column(name = "employee_active")
    private String employeeActive;
    @Column(name = "employee_platform")
    private BigDecimal employeePlatform;
    @Column(name = "employee_discount")
    private BigDecimal employeeDiscount;
    @Column(name = "employee_status_bonus")
    private String employeeStatusBonus;
    @Lob
    @Column(name = "employee_description")
    private String employeeDescription;
    @OneToMany(mappedBy = "historyEmployeeId")
    @JoinColumn(name = "employee_sex_id", referencedColumnName = "sex_id")
    @ManyToOne
    private GapMasterSex employeeSexId;
    @JoinColumn(name = "employee_religion_id", referencedColumnName = "religion_id")
    @ManyToOne
    private GapMasterReligion employeeReligionId;
    @JoinColumn(name = "employee_job_position_id", referencedColumnName = "employee_position_id")
    @ManyToOne
    private GapMasterEmployeePosition employeeJobPositionId;
    @JoinColumn(name = "employee_education_id", referencedColumnName = "employee_education_id")
    @ManyToOne
    private GapMasterEmployeeEducation employeeEducationId;
    @JoinColumn(name = "employee_status_id", referencedColumnName = "employee_status_id")
    @ManyToOne
    private GapMasterEmployeeStatus employeeStatusId;
    @JoinColumn(name = "employee_user_id", referencedColumnName = "user_id")
    @ManyToOne
    private MasterUser employeeUserId;

    
    public GapMasterEmployee() {
    }

    public GapMasterEmployee(Integer employeeId) {
        this.employeeId = employeeId;
    }

    public String getSync() {
        return sync;
    }

    public void setSync(String sync) {
        this.sync = sync;
    }

    public Integer getEmployeeId() {
        return employeeId;
    }

    public void setEmployeeId(Integer employeeId) {
        this.employeeId = employeeId;
    }

    public Integer getEmployeeFinger() {
        return employeeFinger;
    }

    public void setEmployeeFinger(Integer employeeFinger) {
        this.employeeFinger = employeeFinger;
    }

    public String getEmployeeNumber() {
        return employeeNumber;
    }

    public void setEmployeeNumber(String employeeNumber) {
        this.employeeNumber = employeeNumber;
    }

    public String getEmployeeNameFirst() {
        return employeeNameFirst;
    }

    public void setEmployeeNameFirst(String employeeNameFirst) {
        this.employeeNameFirst = employeeNameFirst;
    }

    public String getEmployeeNameMiddle() {
        return employeeNameMiddle;
    }

    public void setEmployeeNameMiddle(String employeeNameMiddle) {
        this.employeeNameMiddle = employeeNameMiddle;
    }

    public String getEmployeeNameLast() {
        return employeeNameLast;
    }

    public void setEmployeeNameLast(String employeeNameLast) {
        this.employeeNameLast = employeeNameLast;
    }

    public String getEmployeeTitleFirst() {
        return employeeTitleFirst;
    }

    public void setEmployeeTitleFirst(String employeeTitleFirst) {
        this.employeeTitleFirst = employeeTitleFirst;
    }

    public String getEmployeeTitleLast() {
        return employeeTitleLast;
    }

    public void setEmployeeTitleLast(String employeeTitleLast) {
        this.employeeTitleLast = employeeTitleLast;
    }

    public Date getEmployeeDateOfBirth() {
        return employeeDateOfBirth;
    }

    public void setEmployeeDateOfBirth(Date employeeDateOfBirth) {
        this.employeeDateOfBirth = employeeDateOfBirth;
    }

    public String getEmployeePlaceOfBirth() {
        return employeePlaceOfBirth;
    }

    public void setEmployeePlaceOfBirth(String employeePlaceOfBirth) {
        this.employeePlaceOfBirth = employeePlaceOfBirth;
    }

    public String getEmployeeIdNumber() {
        return employeeIdNumber;
    }

    public void setEmployeeIdNumber(String employeeIdNumber) {
        this.employeeIdNumber = employeeIdNumber;
    }

    public String getEmployeeAddress() {
        return employeeAddress;
    }

    public void setEmployeeAddress(String employeeAddress) {
        this.employeeAddress = employeeAddress;
    }

    public String getEmployeePostalCode() {
        return employeePostalCode;
    }

    public void setEmployeePostalCode(String employeePostalCode) {
        this.employeePostalCode = employeePostalCode;
    }

    public String getEmployeePhone() {
        return employeePhone;
    }

    public void setEmployeePhone(String employeePhone) {
        this.employeePhone = employeePhone;
    }

    public String getEmployeeMobilePhone() {
        return employeeMobilePhone;
    }

    public void setEmployeeMobilePhone(String employeeMobilePhone) {
        this.employeeMobilePhone = employeeMobilePhone;
    }

    public String getEmployeeEmail() {
        return employeeEmail;
    }

    public void setEmployeeEmail(String employeeEmail) {
        this.employeeEmail = employeeEmail;
    }

    public String getEmployeeMarried() {
        return employeeMarried;
    }

    public void setEmployeeMarried(String employeeMarried) {
        this.employeeMarried = employeeMarried;
    }

    public Date getEmployeeRegistered() {
        return employeeRegistered;
    }

    public void setEmployeeRegistered(Date employeeRegistered) {
        this.employeeRegistered = employeeRegistered;
    }

    public BigDecimal getEmployeeSalaryBasic() {
        return employeeSalaryBasic;
    }

    public void setEmployeeSalaryBasic(BigDecimal employeeSalaryBasic) {
        this.employeeSalaryBasic = employeeSalaryBasic;
    }

    public String getEmployeePaymentMethod() {
        return employeePaymentMethod;
    }

    public void setEmployeePaymentMethod(String employeePaymentMethod) {
        this.employeePaymentMethod = employeePaymentMethod;
    }

    public String getEmployeeBankAccount() {
        return employeeBankAccount;
    }

    public void setEmployeeBankAccount(String employeeBankAccount) {
        this.employeeBankAccount = employeeBankAccount;
    }

    public String getEmployeeBankAccountNumber() {
        return employeeBankAccountNumber;
    }

    public void setEmployeeBankAccountNumber(String employeeBankAccountNumber) {
        this.employeeBankAccountNumber = employeeBankAccountNumber;
    }

    public String getEmployeeBankAccountName() {
        return employeeBankAccountName;
    }

    public void setEmployeeBankAccountName(String employeeBankAccountName) {
        this.employeeBankAccountName = employeeBankAccountName;
    }

    public String getEmployeeDelegation() {
        return employeeDelegation;
    }

    public void setEmployeeDelegation(String employeeDelegation) {
        this.employeeDelegation = employeeDelegation;
    }

    public String getEmployeeActive() {
        return employeeActive;
    }

    public void setEmployeeActive(String employeeActive) {
        this.employeeActive = employeeActive;
    }

    public String getEmployeeStatusBonus() {
        return employeeStatusBonus;
    }

    public void setEmployeeStatusBonus(String employeeStatusBonus) {
        this.employeeStatusBonus = employeeStatusBonus;
    }

    public String getEmployeeDescription() {
        return employeeDescription;
    }

    public void setEmployeeDescription(String employeeDescription) {
        this.employeeDescription = employeeDescription;
    }

    public GapMasterSex getEmployeeSexId() {
        return employeeSexId;
    }

    public void setEmployeeSexId(GapMasterSex employeeSexId) {
        this.employeeSexId = employeeSexId;
    }

    public GapMasterReligion getEmployeeReligionId() {
        return employeeReligionId;
    }

    public void setEmployeeReligionId(GapMasterReligion employeeReligionId) {
        this.employeeReligionId = employeeReligionId;
    }

    public GapMasterEmployeePosition getEmployeeJobPositionId() {
        return employeeJobPositionId;
    }

    public void setEmployeeJobPositionId(GapMasterEmployeePosition employeeJobPositionId) {
        this.employeeJobPositionId = employeeJobPositionId;
    }

    public GapMasterEmployeeEducation getEmployeeEducationId() {
        return employeeEducationId;
    }

    public void setEmployeeEducationId(GapMasterEmployeeEducation employeeEducationId) {
        this.employeeEducationId = employeeEducationId;
    }

    public GapMasterEmployeeStatus getEmployeeStatusId() {
        return employeeStatusId;
    }

    public void setEmployeeStatusId(GapMasterEmployeeStatus employeeStatusId) {
        this.employeeStatusId = employeeStatusId;
    }

    public BigDecimal getEmployeePlatform() {
        return employeePlatform;
    }

    public void setEmployeePlatform(BigDecimal employeePlatform) {
        this.employeePlatform = employeePlatform;
    }

    public MasterUser getEmployeeUserId() {
        return employeeUserId;
    }

    public void setEmployeeUserId(MasterUser employeeUserId) {
        this.employeeUserId = employeeUserId;
    }

    public BigDecimal getEmployeeDiscount() {
        return employeeDiscount;
    }

    public void setEmployeeDiscount(BigDecimal employeeDiscount) {
        this.employeeDiscount = employeeDiscount;
    }

    @Override
    public int hashCode() {
        int hash = 0;
        hash += (employeeId != null ? employeeId.hashCode() : 0);
        return hash;
    }

    @Override
    public boolean equals(Object object) {
        // TODO: Warning - this method won't work in the case the id fields are not set
        if (!(object instanceof GapMasterEmployee)) {
            return false;
        }
        GapMasterEmployee other = (GapMasterEmployee) object;
        if ((this.employeeId == null && other.employeeId != null) || (this.employeeId != null && !this.employeeId.equals(other.employeeId))) {
            return false;
        }
        return true;
    }

    @Override
    public String toString() {
        return employeeNumber;
//        return "com.gap.entities.GapMasterEmployee[ employeeId=" + employeeId + " ]";
    }
    
}
